package com.gitee.wsl.coroutines.exception


/**
 * Utilities for handling uncaught exceptions.
 */
object UncaughtExceptionHandler {

    fun rethrowIfFatal(e: Throwable?) {
        //if (e is StackOverflowError) {
            // Stack-overflows should be reported as-is, instead of crashing
            // the process
        //    return
        //}
        if (e is Error) {
            throw e
        }
    }
}
